<!DOCTYPE html>
<html lang="en-US">
  <head>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width,initial-scale=1">
    <title>8. 分治法求最大子数组 | 被删的前端游乐场</title>
    <meta name="description" content="Just playing around">
    
    
    <link rel="preload" href="/front-end-playground/assets/css/0.styles.a683ed26.css" as="style"><link rel="preload" href="/front-end-playground/assets/js/app.e5cf4092.js" as="script"><link rel="preload" href="/front-end-playground/assets/js/3.c853767c.js" as="script"><link rel="preload" href="/front-end-playground/assets/js/2.eed49fdd.js" as="script"><link rel="preload" href="/front-end-playground/assets/js/25.0876d981.js" as="script">
    <link rel="stylesheet" href="/front-end-playground/assets/css/0.styles.a683ed26.css">
  </head>
  <body>
    <div id="app" data-server-rendered="true"><div class="theme-container"><header class="navbar"><div class="sidebar-button"><svg xmlns="http://www.w3.org/2000/svg" aria-hidden="true" role="img" viewBox="0 0 448 512" class="icon"><path fill="currentColor" d="M436 124H12c-6.627 0-12-5.373-12-12V80c0-6.627 5.373-12 12-12h424c6.627 0 12 5.373 12 12v32c0 6.627-5.373 12-12 12zm0 160H12c-6.627 0-12-5.373-12-12v-32c0-6.627 5.373-12 12-12h424c6.627 0 12 5.373 12 12v32c0 6.627-5.373 12-12 12zm0 160H12c-6.627 0-12-5.373-12-12v-32c0-6.627 5.373-12 12-12h424c6.627 0 12 5.373 12 12v32c0 6.627-5.373 12-12 12z"></path></svg></div> <a href="/front-end-playground/" class="home-link router-link-active"><!----> <span class="site-name">被删的前端游乐场</span></a> <div class="links"><div class="search-box"><input aria-label="Search" autocomplete="off" spellcheck="false" value=""> <!----></div> <nav class="nav-links can-hide"><div class="nav-item"><a href="/front-end-playground/" class="nav-link">概述</a></div><div class="nav-item"><a href="/front-end-playground/front-end-basic/" class="nav-link">前端基础</a></div><div class="nav-item"><a href="/front-end-playground/vue/" class="nav-link">Vue学习</a></div><div class="nav-item"><a href="/front-end-playground/wxapp/" class="nav-link">小程序学习</a></div><div class="nav-item"><a href="/front-end-playground/front-end-others/" class="nav-link">百家齐放</a></div><div class="nav-item"><a href="/front-end-playground/front-end-addon/" class="nav-link router-link-active">前端的进击</a></div><div class="nav-item"><a href="/front-end-playground/faq.html" class="nav-link">FAQ</a></div> <a href="https://github.com/godbasin/front-end-playground" target="_blank" rel="noopener noreferrer" class="repo-link">
    Github
    <svg xmlns="http://www.w3.org/2000/svg" aria-hidden="true" x="0px" y="0px" viewBox="0 0 100 100" width="15" height="15" class="icon outbound"><path fill="currentColor" d="M18.8,85.1h56l0,0c2.2,0,4-1.8,4-4v-32h-8v28h-48v-48h28v-8h-32l0,0c-2.2,0-4,1.8-4,4v56C14.8,83.3,16.6,85.1,18.8,85.1z"></path> <polygon fill="currentColor" points="45.7,48.7 51.3,54.3 77.2,28.5 77.2,37.2 85.2,37.2 85.2,14.9 62.8,14.9 62.8,22.9 71.5,22.9"></polygon></svg></a></nav></div></header> <div class="sidebar-mask"></div> <aside class="sidebar"><nav class="nav-links"><div class="nav-item"><a href="/front-end-playground/" class="nav-link">概述</a></div><div class="nav-item"><a href="/front-end-playground/front-end-basic/" class="nav-link">前端基础</a></div><div class="nav-item"><a href="/front-end-playground/vue/" class="nav-link">Vue学习</a></div><div class="nav-item"><a href="/front-end-playground/wxapp/" class="nav-link">小程序学习</a></div><div class="nav-item"><a href="/front-end-playground/front-end-others/" class="nav-link">百家齐放</a></div><div class="nav-item"><a href="/front-end-playground/front-end-addon/" class="nav-link router-link-active">前端的进击</a></div><div class="nav-item"><a href="/front-end-playground/faq.html" class="nav-link">FAQ</a></div> <a href="https://github.com/godbasin/front-end-playground" target="_blank" rel="noopener noreferrer" class="repo-link">
    Github
    <svg xmlns="http://www.w3.org/2000/svg" aria-hidden="true" x="0px" y="0px" viewBox="0 0 100 100" width="15" height="15" class="icon outbound"><path fill="currentColor" d="M18.8,85.1h56l0,0c2.2,0,4-1.8,4-4v-32h-8v28h-48v-48h28v-8h-32l0,0c-2.2,0-4,1.8-4,4v56C14.8,83.3,16.6,85.1,18.8,85.1z"></path> <polygon fill="currentColor" points="45.7,48.7 51.3,54.3 77.2,28.5 77.2,37.2 85.2,37.2 85.2,14.9 62.8,14.9 62.8,22.9 71.5,22.9"></polygon></svg></a></nav>  <ul class="sidebar-links"><li><section class="sidebar-group collapsable depth-0" style="padding-top:;"><!----> <p class="sidebar-heading"><span>不止单线程</span> <span class="arrow right"></span></p> <!----></section></li><li><section class="sidebar-group collapsable depth-0" style="padding-top:10px;"><div class="kitty-main" data-v-0cd75e06><span class="stand" data-v-0cd75e06></span> <div class="cat" data-v-0cd75e06><div class="body" data-v-0cd75e06></div> <div class="head" data-v-0cd75e06><div class="ear" data-v-0cd75e06></div> <div class="ear" data-v-0cd75e06></div></div> <div class="face" data-v-0cd75e06><div class="nose" data-v-0cd75e06></div> <div class="whisker-container" data-v-0cd75e06><div class="whisker" data-v-0cd75e06></div> <div class="whisker" data-v-0cd75e06></div></div> <div class="whisker-container" data-v-0cd75e06><div class="whisker" data-v-0cd75e06></div> <div class="whisker" data-v-0cd75e06></div></div></div> <div class="tail-container" data-v-0cd75e06><div class="tail" data-v-0cd75e06><div class="tail" data-v-0cd75e06><div class="tail" data-v-0cd75e06><div class="tail" data-v-0cd75e06><div class="tail" data-v-0cd75e06><div class="tail" data-v-0cd75e06><div class="tail" data-v-0cd75e06></div></div></div></div></div></div></div></div></div></div> <p class="sidebar-heading open"><span>简单算法之 js 实现</span> <span class="arrow down"></span></p> <ul class="sidebar-links sidebar-group-items"><li><a href="/front-end-playground/front-end-addon/simple-algorithm/1-bubble-sort.html" class="sidebar-link">1. 冒泡排序</a></li><li><a href="/front-end-playground/front-end-addon/simple-algorithm/2-counting-sort.html" class="sidebar-link">2. 计数排序</a></li><li><a href="/front-end-playground/front-end-addon/simple-algorithm/3-insertion-sort.html" class="sidebar-link">3. 插入排序</a></li><li><a href="/front-end-playground/front-end-addon/simple-algorithm/4-merge-sort.html" class="sidebar-link">4. 归并排序</a></li><li><a href="/front-end-playground/front-end-addon/simple-algorithm/5-quick-sort.html" class="sidebar-link">5. 快速排序</a></li><li><a href="/front-end-playground/front-end-addon/simple-algorithm/6-heap-sort.html" class="sidebar-link">6. 堆排序</a></li><li><a href="/front-end-playground/front-end-addon/simple-algorithm/7-quick-select.html" class="sidebar-link">7. 快速选择</a></li><li><a href="/front-end-playground/front-end-addon/simple-algorithm/8-find-maximum-subarray.html" class="active sidebar-link">8. 分治法求最大子数组</a><ul class="sidebar-sub-headers"><li class="sidebar-sub-header"><a href="/front-end-playground/front-end-addon/simple-algorithm/8-find-maximum-subarray.html#分治法" class="sidebar-link">分治法</a></li><li class="sidebar-sub-header"><a href="/front-end-playground/front-end-addon/simple-algorithm/8-find-maximum-subarray.html#最大子数组问题" class="sidebar-link">最大子数组问题</a></li><li class="sidebar-sub-header"><a href="/front-end-playground/front-end-addon/simple-algorithm/8-find-maximum-subarray.html#分治策略思路" class="sidebar-link">分治策略思路</a></li><li class="sidebar-sub-header"><a href="/front-end-playground/front-end-addon/simple-algorithm/8-find-maximum-subarray.html#js-实现" class="sidebar-link">js 实现</a></li><li class="sidebar-sub-header"><a href="/front-end-playground/front-end-addon/simple-algorithm/8-find-maximum-subarray.html#验证" class="sidebar-link">验证</a></li></ul></li><li><a href="/front-end-playground/front-end-addon/simple-algorithm/9-n-n-matrix.html" class="sidebar-link">9. n×n 矩阵计算</a></li></ul></section></li><li><section class="sidebar-group collapsable depth-0" style="padding-top:;"><!----> <p class="sidebar-heading"><span>不止纯前端</span> <span class="arrow right"></span></p> <!----></section></li></ul> </aside> <main class="page"> <div class="theme-default-content content__default"><p>分治法求最大子数组的 javascript 实现。</p> <h1 id="分治法求最大子数组"><a href="#分治法求最大子数组" aria-hidden="true" class="header-anchor">#</a> 分治法求最大子数组</h1> <h2 id="分治法"><a href="#分治法" aria-hidden="true" class="header-anchor">#</a> 分治法</h2> <p>分治策略递归求解一个问题，在每层递归中：</p> <ul><li>分解(Divide)步骤：将问题划分未一些子问题，子问题的形式与原问题一样，只是规模更小</li> <li>解决(Conquer)步骤：递归地求解出子问题。如果子问题的规模足够小，则停止递归，直接求解</li> <li>合并(Combine)步骤：将子问题的解组合成原问题的解</li></ul> <h2 id="最大子数组问题"><a href="#最大子数组问题" aria-hidden="true" class="header-anchor">#</a> 最大子数组问题</h2> <p>求数组的和最大的非空连续子数组，即最大子数组。</p> <h2 id="分治策略思路"><a href="#分治策略思路" aria-hidden="true" class="header-anchor">#</a> 分治策略思路</h2> <p>将子数组划分为两个规模尽量相等的子数组，<code>A[low, ..., high]</code>的一个最大子数组<code>A[i, .., j]</code>所处的位置必然是三种情况之一：</p> <ul><li>完全位于子数组<code>A[low, ..., mid]</code>中，<code>low &lt;= i &lt;= j &lt;= mid</code></li> <li>完全位于子数组<code>A[mid + 1, ..., high]</code>中，<code>mid &lt;= i &lt;= j &lt;= high</code></li> <li>跨越了中点，<code>low &lt;= i &lt;= mid &lt; j &lt;= high</code></li></ul> <p>可递归求解<code>A[low, ..., mid]</code>和<code>A[mid + 1, ..., high]</code>。</p> <p>求解跨越中点的最大子数组的思路：</p> <ol><li>循环求出<code>A[i, ..., mid]</code>以及<code>A[mid + 1, ..., j]</code>的最大和</li> <li>合并返回左侧和右侧最大和</li></ol> <h2 id="js-实现"><a href="#js-实现" aria-hidden="true" class="header-anchor">#</a> js 实现</h2> <div class="language-javascript extra-class"><pre class="language-javascript"><code><span class="token keyword">function</span> <span class="token function">findMaxSubarray</span><span class="token punctuation">(</span><span class="token parameter">iArr<span class="token punctuation">,</span> low<span class="token punctuation">,</span> high</span><span class="token punctuation">)</span> <span class="token punctuation">{</span>
  <span class="token comment">// 求解跨越中点的最大子数组</span>
  <span class="token keyword">function</span> <span class="token function">findMaxCrossingSubarray</span><span class="token punctuation">(</span><span class="token parameter">arr<span class="token punctuation">,</span> low<span class="token punctuation">,</span> mid<span class="token punctuation">,</span> high</span><span class="token punctuation">)</span> <span class="token punctuation">{</span>
    <span class="token keyword">var</span> leftSum <span class="token operator">=</span> arr<span class="token punctuation">[</span>mid<span class="token punctuation">]</span><span class="token punctuation">;</span>
    <span class="token keyword">var</span> rightSum <span class="token operator">=</span> arr<span class="token punctuation">[</span>mid <span class="token operator">+</span> <span class="token number">1</span><span class="token punctuation">]</span><span class="token punctuation">;</span>
    <span class="token keyword">var</span> left <span class="token operator">=</span> mid<span class="token punctuation">,</span>
      right <span class="token operator">=</span> mid <span class="token operator">+</span> <span class="token number">1</span><span class="token punctuation">;</span>
    <span class="token comment">// 遍历左侧，找出左侧最大和</span>
    <span class="token keyword">for</span> <span class="token punctuation">(</span><span class="token keyword">var</span> i <span class="token operator">=</span> mid<span class="token punctuation">,</span> sum <span class="token operator">=</span> <span class="token number">0</span><span class="token punctuation">;</span> i <span class="token operator">&gt;=</span> low<span class="token punctuation">;</span> i<span class="token operator">--</span><span class="token punctuation">)</span> <span class="token punctuation">{</span>
      sum <span class="token operator">+=</span> arr<span class="token punctuation">[</span>i<span class="token punctuation">]</span><span class="token punctuation">;</span>
      <span class="token keyword">if</span> <span class="token punctuation">(</span>sum <span class="token operator">&gt;</span> leftSum<span class="token punctuation">)</span> <span class="token punctuation">{</span>
        leftSum <span class="token operator">=</span> sum<span class="token punctuation">;</span>
        left <span class="token operator">=</span> i<span class="token punctuation">;</span>
      <span class="token punctuation">}</span>
    <span class="token punctuation">}</span>
    <span class="token comment">// 遍历右侧，找出右侧最大和</span>
    <span class="token keyword">for</span> <span class="token punctuation">(</span><span class="token keyword">var</span> j <span class="token operator">=</span> mid <span class="token operator">+</span> <span class="token number">1</span><span class="token punctuation">,</span> sum <span class="token operator">=</span> <span class="token number">0</span><span class="token punctuation">;</span> j <span class="token operator">&lt;=</span> high<span class="token punctuation">;</span> j<span class="token operator">++</span><span class="token punctuation">)</span> <span class="token punctuation">{</span>
      sum <span class="token operator">+=</span> arr<span class="token punctuation">[</span>j<span class="token punctuation">]</span><span class="token punctuation">;</span>
      <span class="token keyword">if</span> <span class="token punctuation">(</span>sum <span class="token operator">&gt;</span> rightSum<span class="token punctuation">)</span> <span class="token punctuation">{</span>
        rightSum <span class="token operator">=</span> sum<span class="token punctuation">;</span>
        right <span class="token operator">=</span> j<span class="token punctuation">;</span>
      <span class="token punctuation">}</span>
    <span class="token punctuation">}</span>
    <span class="token keyword">return</span> <span class="token punctuation">[</span>leftSum <span class="token operator">+</span> rightSum<span class="token punctuation">,</span> left<span class="token punctuation">,</span> right<span class="token punctuation">]</span><span class="token punctuation">;</span>
  <span class="token punctuation">}</span>

  <span class="token keyword">if</span> <span class="token punctuation">(</span>high <span class="token operator">===</span> low<span class="token punctuation">)</span> <span class="token punctuation">{</span>
    <span class="token comment">// 若只有一个数，返回该数</span>
    <span class="token keyword">return</span> <span class="token punctuation">[</span>iArr<span class="token punctuation">[</span>low<span class="token punctuation">]</span><span class="token punctuation">,</span> low<span class="token punctuation">,</span> high<span class="token punctuation">]</span><span class="token punctuation">;</span>
  <span class="token punctuation">}</span> <span class="token keyword">else</span> <span class="token punctuation">{</span>
    <span class="token comment">// 取中间数</span>
    <span class="token keyword">var</span> mid <span class="token operator">=</span> <span class="token function">parseInt</span><span class="token punctuation">(</span><span class="token punctuation">(</span>high <span class="token operator">+</span> low<span class="token punctuation">)</span> <span class="token operator">/</span> <span class="token number">2</span><span class="token punctuation">)</span><span class="token punctuation">;</span>
    <span class="token comment">// 递归求左侧最大子数组</span>
    <span class="token keyword">var</span> result1 <span class="token operator">=</span> <span class="token function">findMaxSubarray</span><span class="token punctuation">(</span>iArr<span class="token punctuation">,</span> low<span class="token punctuation">,</span> mid<span class="token punctuation">)</span><span class="token punctuation">;</span>
    <span class="token comment">// 递归求右侧最大子数组</span>
    <span class="token keyword">var</span> result2 <span class="token operator">=</span> <span class="token function">findMaxSubarray</span><span class="token punctuation">(</span>iArr<span class="token punctuation">,</span> mid <span class="token operator">+</span> <span class="token number">1</span><span class="token punctuation">,</span> high<span class="token punctuation">)</span><span class="token punctuation">;</span>
    <span class="token comment">// 求跨越中点的最大子数组</span>
    <span class="token keyword">var</span> result3 <span class="token operator">=</span> <span class="token function">findMaxCrossingSubarray</span><span class="token punctuation">(</span>iArr<span class="token punctuation">,</span> low<span class="token punctuation">,</span> mid<span class="token punctuation">,</span> high<span class="token punctuation">)</span><span class="token punctuation">;</span>

    <span class="token comment">// 比较三个子数组，然后返回最大</span>
    <span class="token keyword">if</span> <span class="token punctuation">(</span>result1<span class="token punctuation">[</span><span class="token number">0</span><span class="token punctuation">]</span> <span class="token operator">&gt;</span> result2<span class="token punctuation">[</span><span class="token number">0</span><span class="token punctuation">]</span> <span class="token operator">&amp;&amp;</span> result1<span class="token punctuation">[</span><span class="token number">0</span><span class="token punctuation">]</span> <span class="token operator">&gt;</span> result3<span class="token punctuation">[</span><span class="token number">0</span><span class="token punctuation">]</span><span class="token punctuation">)</span> <span class="token punctuation">{</span>
      <span class="token keyword">return</span> result1<span class="token punctuation">;</span>
    <span class="token punctuation">}</span> <span class="token keyword">else</span> <span class="token keyword">if</span> <span class="token punctuation">(</span>result1<span class="token punctuation">[</span><span class="token number">0</span><span class="token punctuation">]</span> <span class="token operator">&gt;</span> result2<span class="token punctuation">[</span><span class="token number">0</span><span class="token punctuation">]</span><span class="token punctuation">)</span> <span class="token punctuation">{</span>
      <span class="token keyword">return</span> result3<span class="token punctuation">;</span>
    <span class="token punctuation">}</span> <span class="token keyword">else</span> <span class="token punctuation">{</span>
      <span class="token keyword">return</span> result3<span class="token punctuation">[</span><span class="token number">0</span><span class="token punctuation">]</span> <span class="token operator">&gt;</span> result2<span class="token punctuation">[</span><span class="token number">0</span><span class="token punctuation">]</span> <span class="token operator">?</span> result3 <span class="token punctuation">:</span> result2<span class="token punctuation">;</span>
    <span class="token punctuation">}</span>
  <span class="token punctuation">}</span>
<span class="token punctuation">}</span>
</code></pre></div><h2 id="验证"><a href="#验证" aria-hidden="true" class="header-anchor">#</a> 验证</h2> <div class="language-javascript extra-class"><pre class="language-javascript"><code><span class="token keyword">var</span> inputArr <span class="token operator">=</span> <span class="token punctuation">[</span>
  <span class="token number">13</span><span class="token punctuation">,</span>
  <span class="token operator">-</span><span class="token number">3</span><span class="token punctuation">,</span>
  <span class="token operator">-</span><span class="token number">25</span><span class="token punctuation">,</span>
  <span class="token number">20</span><span class="token punctuation">,</span>
  <span class="token operator">-</span><span class="token number">3</span><span class="token punctuation">,</span>
  <span class="token operator">-</span><span class="token number">16</span><span class="token punctuation">,</span>
  <span class="token operator">-</span><span class="token number">23</span><span class="token punctuation">,</span>
  <span class="token number">18</span><span class="token punctuation">,</span>
  <span class="token number">20</span><span class="token punctuation">,</span>
  <span class="token operator">-</span><span class="token number">7</span><span class="token punctuation">,</span>
  <span class="token number">12</span><span class="token punctuation">,</span>
  <span class="token operator">-</span><span class="token number">5</span><span class="token punctuation">,</span>
  <span class="token operator">-</span><span class="token number">22</span><span class="token punctuation">,</span>
  <span class="token number">15</span><span class="token punctuation">,</span>
  <span class="token operator">-</span><span class="token number">4</span><span class="token punctuation">,</span>
  <span class="token number">7</span>
<span class="token punctuation">]</span><span class="token punctuation">;</span>
<span class="token function">findMaxSubarray</span><span class="token punctuation">(</span>inputArr<span class="token punctuation">,</span> <span class="token number">0</span><span class="token punctuation">,</span> inputArr<span class="token punctuation">.</span>length <span class="token operator">-</span> <span class="token number">1</span><span class="token punctuation">)</span><span class="token punctuation">;</span>
<span class="token comment">// 输出[43, 7, 10]，即最大和43，子数组为inputArr[7, 10]</span>
</code></pre></div></div> <!----> <footer class="page-edit"><div class="edit-link"><a href="https://github.com/godbasin/front-end-playground/edit/sourcecode/docs/front-end-addon/simple-algorithm/8-find-maximum-subarray.md" target="_blank" rel="noopener noreferrer">帮阿猪改善此页面！</a> <svg xmlns="http://www.w3.org/2000/svg" aria-hidden="true" x="0px" y="0px" viewBox="0 0 100 100" width="15" height="15" class="icon outbound"><path fill="currentColor" d="M18.8,85.1h56l0,0c2.2,0,4-1.8,4-4v-32h-8v28h-48v-48h28v-8h-32l0,0c-2.2,0-4,1.8-4,4v56C14.8,83.3,16.6,85.1,18.8,85.1z"></path> <polygon fill="currentColor" points="45.7,48.7 51.3,54.3 77.2,28.5 77.2,37.2 85.2,37.2 85.2,14.9 62.8,14.9 62.8,22.9 71.5,22.9"></polygon></svg></div> <!----> <blockquote>部分文章中使用了一些网站的截图，如果涉及侵权，请告诉我删一下谢谢~</blockquote> <div style="margin-top:30px;"><div class="el-row" style="margin-left:-10px;margin-right:-10px;"><div class="el-col el-col-24 el-col-sm-0 el-col-md-2 el-col-lg-4" style="padding-left:10px;padding-right:10px;display:block;"><div style="width:1px;height:1px;"></div></div> <div class="el-col el-col-24 el-col-sm-24 el-col-md-18 el-col-lg-16" style="padding-left:10px;padding-right:10px;"><div class="el-card box-card is-always-shadow"><div class="el-card__header"><div class="clearfix"><span>温馨提示喵</span></div></div><div class="el-card__body"> <div class="el-row" style="margin-left:-10px;margin-right:-10px;"><div class="el-col el-col-24 el-col-xs-24 el-col-sm-12" style="padding-left:10px;padding-right:10px;"><div class="el-image"><div class="image-slot"><img src="https://github-imglib-1255459943.cos.ap-chengdu.myqcloud.com/assets/img/loading.gif" style="width:100%;"></div><!----></div></div> <div class="el-col el-col-24 el-col-xs-24 el-col-sm-12" style="padding-left:10px;padding-right:10px;"><div class="copyright-text"><div>本文版权归作者所有，欢迎转载，但未经作者同意必须保留此段声明，且在文章页面明显位置给出原文连接，否则保留追究法律责任的权利。</div> <div>出处：被删的前端游乐场</div> <div>作者：<a href="https://github.com/godbasin" target="_blank">被删</a></div></div></div></div></div></div></div></div></div></footer> <div class="page-nav"><p class="inner"><span class="prev">
        ←
        <a href="/front-end-playground/front-end-addon/simple-algorithm/7-quick-select.html" class="prev">
          7. 快速选择
        </a></span> <span class="next"><a href="/front-end-playground/front-end-addon/simple-algorithm/9-n-n-matrix.html">
          9. n×n 矩阵计算
        </a>
        →
      </span></p></div>  <div class="gitalk-container theme-default-content"><div id="gitalk-container" class="content"></div></div></main> <div id="kitty-container"><span><div role="tooltip" id="el-popover-6679" aria-hidden="true" class="el-popover el-popper" style="width:undefinedpx;display:none;"><!----><img src="https://github-imglib-1255459943.cos.ap-chengdu.myqcloud.com/2code2.jpg" class="image"> <div class="text">牡羊猪的猫粮罐</div> </div><div id="kitty" style="background:url(https://github-imglib-1255459943.cos.ap-chengdu.myqcloud.com/assets/img/kitty0.svg);"></div></span> <div class="el-dialog__wrapper" style="display:none;"><div role="dialog" aria-modal="true" aria-label="牡羊猪是这样渐渐胖成猪的喵（点击图片可以切换噢）" class="el-dialog" style="margin-top:15vh;"><div class="el-dialog__header"><span class="el-dialog__title">牡羊猪是这样渐渐胖成猪的喵（点击图片可以切换噢）</span><button type="button" aria-label="Close" class="el-dialog__headerbtn"><i class="el-dialog__close el-icon el-icon-close"></i></button></div><!----><!----></div></div></div></div><div class="global-ui"></div></div>
    <script src="/front-end-playground/assets/js/app.e5cf4092.js" defer></script><script src="/front-end-playground/assets/js/3.c853767c.js" defer></script><script src="/front-end-playground/assets/js/2.eed49fdd.js" defer></script><script src="/front-end-playground/assets/js/25.0876d981.js" defer></script>
  </body>
</html>
